//
//  FormCell.m
//  UI_通讯_26
//
//  Created by dllo on 15/11/21.
//  Copyright © 2015年 liwenhan. All rights reserved.
//

#import "FormCell.h"
#define WIDTH self.contentView.frame.size.width
#define HEIGHT self.contentView.frame.size.height

@implementation FormCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.nameLabel = [[UILabel alloc]init];
        [self.contentView addSubview:self.nameLabel];
        
        self.phoneLabel = [[UILabel alloc]init];
        [self.contentView addSubview:self.nameLabel];
        
        self.headView = [[UIImageView alloc]init];
        [self.contentView addSubview:self.headView];
    }
    return self;
}

- (void)layoutSubviews
{
    [super layoutSubviews];
    self.nameLabel.frame = CGRectMake(100, 20, WIDTH - 120, 30);
    self.phoneLabel.frame = CGRectMake(100, 50, WIDTH - 120, 30);
    
    self.headView.frame =CGRectMake(20, 20, 100 - 40, 100 - 40);
    self.headView.layer.cornerRadius = 30;
    self.headView.layer.masksToBounds = YES;
}


- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
